package org.example.controller;

import net.itbaima.robot.service.RobotService;
import net.mamoe.mirai.Bot;
import net.mamoe.mirai.BotFactory;
import net.mamoe.mirai.contact.ContactList;
import net.mamoe.mirai.contact.Friend;
import net.mamoe.mirai.contact.Group;
import net.mamoe.mirai.utils.BotConfiguration;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @ Tool：IntelliJ IDEA
 * @ Author：hl
 * @ Date：2024-05-17-下午12:31
 */
@RestController
@RequestMapping("test")
public class testController {
    @Autowired
    RobotService service;
    @PostMapping("/a")
    public Object index() {
        service.sendMessageToGroup(960899275,"32323223");
        return"security jwt";
    }

    @GetMapping("/b")
    public Object b() {
        service.sendMessageToGroup(744969237 ,"QQ机器人，有没有让按照文档弄过啊，有些问题需要请假一下，有偿！！");
        return"security jwt";
    }
}
